MD-2100RTU communication driver

 

MD-2100RTU communication driver is the driver to communicate with rain gauge of JongSung Tech Co., Ltd. in Korea.

 

1. Read Settings

 

<Figure 1> is read setting example of MD-2100RTU communication driver.

 
<Figure 1>  Read setting example of MD-2100RTU communication driver

Device part of  <Figure 1> input Device type(TCP/IP), IP address of controller(192.168.0.120), service port ( 6001 ),respectively, according to setting of controller.

Device of MD-2100RTU communication driver normally use TCP/IP ( or UDP/IP ), but you can use serila mode. ( example : COM1, 9600, 0, 8, 1 )

Also, you can set 'Old Data Save Tag',  whether to use 'Hex Time'(0 = decimal BCD, 1 = hex-decimal, default = 0) are set by using option part. Each argument  is a comma-delimited.

 

MD-2100RTU communication driver read schedule

Read schedule setting parameters are as follows:

1) Station – don't care.

2) Read command – read data type. ( refer to <Table 1> ~ <Table 5> )

CURR – read of current rainfall,

LOG – read of status LOG data,

STS – read of controller status,

TIME – read of current time,

RAIN – read of current rainfall 2 value,

RAIN3 – read of current rainfall 3 value,

RAIN4 – read of rainfall intensity,

RAIN5 – read of the day before rainfall,

VER – read version information.

3) Read start address – don't care.

4) Save start address for Communication Server – Saving start address of Communication Server.

5) Read Size – read size.

 

Read schedule example)

READ,    0,  RAIN5,     0,    0,  1,

 

 

<Table 1> ~ <Table 5> are data saving address and contents for CURR, LOG, STS, RAIN, RAIN3, RAIN4, RAIN5, VER read command.

Data saving address

Contents

Start addr + 0

rainfall of a hour

Start addr + 1

rainfall of today

Start addr + 2

rainfall of sum

Start addr + 3

rainfall of maximum

<Table 1> Data saving address and contents for CURR read command

Data saving address

Contents

Remarks
Start addr + 0 status of blackout 0 ~ 30
Start addr + 1 ~ 4  blackout month, day, hour, minute
Start addr + 5 ~ 8 power failure restoration month, day, hour, minute
Start addr + 9 alarm Off status 40 ~ 60
Start addr + 10 ~ 13 alarm Off month, day, hour, minute
Start addr + 14 ~ 17 alarm  Off return month, day, hour, minute
Start addr + 18 status of printer Off 70 ~ 90
Start addr + 19 ~ 22 printer Off month, day, hour, minute
Start addr + 23 ~ 26 printer Off return month, day, hour, minute
<Table 2> Data saving address and contents for LOG read command

Data saving address

Contents

Remarks
Start addr + 0 ~ 3  blackout month, day, hour, minute normal : 20
Start addr + 4 ~ 7 alarm Off month, day, hour, minute
Start addr + 8 ~ 11 printer Off month, day, hour, minute
<Table 3> Data saving address and contents for STS read command

Data saving address

Contents

Start addr + 0 ~ 5 year, month, day, hour, minute, second
<Table 4> Data saving address and contents for TIME read command
Read command

Data saving address

Contents

RAIN Start addr + 0 ~ 2 rainfall of year, month, day
Start addr + 3 maximum rainfall of a hour
RAIN3 Start addr + 0 ~ 2 rainfall of year, month, day
Start addr + 3 maximum rainfall of a hour
RAIN4 Start addr + 0 rainfall intensity
Start addr + 1 ~ 4 year, month, day, hour, minute
RAIN5 Start addr + 0 ~ 2 rainfall of year, month, day
Start addr + 3 ~ 4 maximum rainfall of a hour, the day before rainfall
VER Start addr + 0 year of version,
save version information at STRING memory
Start addr + 1 ~ 2 month, day of version
<Table 5> Data saving address and contents for RAIN, RAIN3, RAIN4, RAIN5, VER read command

If you click the icon  in protocol option part at <Figure 1>, you can see the dialogue box such as <Figure 2>. you can also set read schedule by using this part. 

 
<Figure 2> Example of MD-2100RTU communication driver¡¯s Option dialog box

You can set read schedule by using , , button and listbox of <Figure 2>.

You can also set Old Data Save Tag,  whether to use Hex Time by using the part of 'Old Data Save Tag', 'time Option' in <Figure 2>.

You can set the default 30Bytes response packet of RAIN5 (read all-in-one reading) to 35Bytes by using the part of  'RAIN5 Option' in <Figure 2>.

 
<Figure 3> Example of MD-2100RTU communication driver¡¯s read schedule Add/Edit dialog box

When you click Add button or Edit button in dialogue box of <Figure 2>, dialogue box of <Figure 3> is shown.

 

2. Writing settings

You can read and write by using 'writing settings'. 

 

Digital Write

Digital write and analog write have the same setting parameters except output value.

 

Analog Write

Analog write setting parameters are as follows:

1)  PORT                   Port no. (0 ~ 255)

2)  STATION             output contents or data year when DATA, SET command.  Note ) 0, 9999 = display controller, other RTU output command.

0  or  9999 – Modern Tech Display – setting of write

DATA, SET command – read of old data, year of data modification request.

other command – don't care. 

3)  ADDRESS          readed data saving start (WORD) address or data month, day.

SET command – month, day of data modification request ( higher 2 digit : month, lower 2 digit : day ),

RESET (RST), SYNC (TSYN ) command  – don't care,

other command – readed data saving start (WORD) address. 

4)  Extra1                  write command.

RESET (RST) – reset of controller,

SYNC (TSYN) – time syncronization, ( time syncronization with computer )

CURR – read of current rainfall,

LOG – read of status LOG data,

STS – read of controller status,

TIME – read of current time,

RAIN – read of current rainfall 2 value,

RAIN3 – read of current rainfall 3 value,

RAIN4 – read of rainfall intensity,

RAIN5 – read of the day before rainfall,

VER – read version information. 

DATA – read of saved old data : output value = old data hour, minute, ( higher 2digit : hour, lower 2digit : minute )

SET – old saved data modification request. 

5) Extra2                   data time setting when DATA, SET command.

DATA command – old data read month, day ( higher 2digit : month, lower 2digit : day ),

SET command – hour, minute of data modification request ( higher 2digit : hour, lower 2digit : minute ),

other command : don't care.

 

Note ) Write command for reading(CURR, LOG, STS, TIME, RAIN, RAIN3, RAIN4, VER, DATA) save the readed data from 'Address' at WORD memory.

The 1st address of saveing data is success flag( 1 : read OK,   0 : read error ).

 

Note ) Readed value for DATA write command save( 1 hour every data ) at 'Analog Input Tag' of 'Old Data Save Tag'.

Data saving address

Contents

 Address + 0 memory read success flag ( 1 : OK  0 : error)
 Address + 1 memory rainfall of a hour
 Address + 2 memory rainfall of totay
 Address + 3 memory rainfall of sum
 Address + 4 memory rainfall of maximum
<Table 6> Data saving address and contents for CURR write command

Data saving address

Contents

Remarks
 Address + 0 memory read success flag  1 : OK  0 : error
 Address + 1 memory status of blackout 0 ~ 30
 Address + 2 ~ 5 memory  blackout month, day, hour, minute
 Address + 6 ~ 9 memory power failure restoration month, day, hour, minute
 Address + 10 memory alarm Off status 40 ~ 60
 Address + 11 ~ 14 memory alarm Off month, day, hour, minute
 Address + 15 ~ 18 memory alarm  Off return month, day, hour, minute
 Address + 19 memory status of printer Off 70 ~ 90
 Address + 20 ~ 23 memory printer Off month, day, hour, minute
 Address + 24 ~ 27 memory printer Off return month, day, hour, minute
<Table 7> Data saving address and contents for LOG read command

Data saving address

Contents

Remarks
 Address + 0 memory read success flag  1 : OK  0 : error
 Address + 1 ~ 4 memory  blackout month, day, hour, minute normal : 20
 Address + 5 ~ 8 memory alarm Off month, day, hour, minute
 Address + 9 ~ 12 memory printer Off month, day, hour, minute
<Table 8> Data saving address and contents for STS write command

Data saving address

Contents

 Address + 0 memory read success flag ( 1 : OK  0 : error)
 Address + 1 ~ 6 memory year, month, day, hour, minute, second
<Table 9> Data saving address and contents for TIME write command

Data saving address

Contents

 Address + 0 memory read success flag ( 1 : OK  0 : error)
 Address + 1 ~ 6 memory 6 saved old data ( each 10 minute period)
<Table 10> Data saving address and contents for DATA write command

Write example 1)

PORT:0,  station:1, ADDRESS:0000, Extra1: RESET,  Extra2 : 0

The setting parameter shown above is RTU reset example.

 

Write example 2)

PORT:0,  station:1, ADDRESS:0000, Extra1: SYNC,  Extra2 : 0

The setting parameter shown above is time syncronization setting example with computer.

 

Write example 3)

PORT:0,  station:2013, ADDRESS:0030, Extra1: DATA,  Extra2 : 0830, Output value = 1300

The setting parameter shown above is saved old data reading example for 2013-08-30 13: 00.

After writing, thed readed data save from 30 address of WORD memory.

Also, save  Tag old data from 2013-08-30 13: 00 to 2013-08-30 13: 59 at 'Old Data Save Tag'.

 

Write example 4)

PORT:0,  station:2013, ADDRESS:0200, Extra1: DATA,  Extra2 : 0615, Output value = 1700

The setting parameter shown above is saved old data reading example for 2013-06-15 17: 00.

After writing, thed readed data save from 200 address of WORD memory.

Also, save  Tag old data from 2013-06-15 17: 00 to 2013-06-15 17: 59 at 'Old Data Save Tag'.

 

Write example 5)

PORT:0,  station:2014, ADDRESS:0109, Extra1: SET,  Extra2 : 1245, Output value = 12

The setting parameter shown above is old data changing example of 2014-01-09 12:45 data, changing value = 12.

 

Write example 5)

PORT:0,  station:2014, ADDRESS:0110, Extra1: SET,  Extra2 : 0932, Output value = 3

The setting parameter shown above is old data changing example of 2014-01-10 09:32 data, changing value = 3.